#include "my_delay.h"
#include "Global.h"


#define HCLK 48000000
#pragma push
#pragma Ospace
#pragma O2
void BOARD_DelayXuS(unsigned     	long X)
{
  #if (HCLK > 48000000ul)
  X *= (((HCLK/1000000)/3) );
  #elif (HCLK > 24000000ul)
  X *= ((HCLK/1000000)/3);
  #else
  X *= ((HCLK/1000000)/2);
  #endif
  while(X--);
}
#pragma pop


void my_nop(void)
{
	__NOP();
}

